package com.example.photo.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.example.photo.model.VO.UserVO;
import com.example.photo.model.domain.User;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * @author 85792
 * @description 针对表【user(用户)】的数据库操作Service
 * @createDate 2023-03-25 19:15:40
 */
public interface UserService extends IService<User> {
    // 账密注册
    UserVO commonUserRegister(String username, String password, String checkPassword, HttpServletResponse response);

    // 账号登录（普通+管理）
    UserVO commonUserLogin(String username, String password, HttpServletResponse response);

    // 学号登录
    UserVO tjuUserLogin(String username, String password, HttpServletResponse response);

    // 检查验证码
    boolean verifyCode(String email, String code, HttpServletRequest request);

    // 发送邮箱验证码
    void sendCode(String email, HttpServletRequest request);

    // 用户修改密码
    void resetPassword(String email, String newPassword);
}
